<template>
  <div class="xtx-panel">
    <div class="container">
      <!-- 上内容 -->
      <div class="head">
        <div class="left">
          <h3>{{props.title}} <span>{{props.subTitle}}</span></h3>
        </div>
        <!-- 上右内容 右插槽-->
        <slot name="right"></slot>
      </div>
      <!-- 下内容 默认插槽-->
      <slot></slot>
    </div>
  </div>
</template>

<script setup>
const props = defineProps({
  title: {
    type: String,
    default: ''
  },
  subTitle: {
    type: String,
    default: ''
  }
})
</script>

<style lang="scss" scoped>
.xtx-panel {
  background-color: #fff;
  .head {
    padding: 40px 0;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    h3 {
      flex: 1;
      font-size: 32px;
      font-weight: normal;
      margin-left: 6px;
      height: 35px;
      line-height: 35px;
      span {
        font-size: 16px;
        color: #999;
        margin-left: 20px;
      }
    }
  }
}
</style>
